#pragma once
#include <SFML/Graphics/Rect.hpp>
#include <SFML/Graphics/View.hpp>
#include <nice2d/predef.h>
#include <nice2d/widgets/control.h>

class MiniMap : public Control
{
    DECLARE_OBJECT(MiniMap)
public:
    MiniMap();
    ~MiniMap();
public:
    void setScene(ScenePointer scene);

    void setArea(const sf::FloatRect &area);
    void setViewport(const sf::FloatRect &viewport);

    sf::View getView()const;
protected:
    void onDrawControl(sf::RenderTarget &target, sf::RenderStates states) const override;
private:
    std::unique_ptr<class MiniMapData> data;
};
